<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
    
<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean" %>
<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html" %>
<%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
<%@page import="support.*, java.util.*, java.sql.*, model.*, data.*" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>

	<%
	Vector<ReviewerInfo> reviewerInfos = (Vector<ReviewerInfo>)request.getAttribute("reviewerInfos");
	Vector<String> reviewers = (Vector<String>)request.getAttribute("reviewers");
	
for(int i4 = 0; i4 < reviewerInfos.size(); i4++){
System.err.println("AppsByReviewer");
System.err.println("reviewerInfos("+i4+") name= "+reviewerInfos.elementAt(i4).getName() );
for(int i5 =0; i5<reviewerInfos.elementAt(i4).getGradedApps().size(); i5++){
System.err.println("gradedApps("+i5+") score= "+reviewerInfos.elementAt(i4).getGradedApps().elementAt(i5).getApplicantName() );
}
for(int i6 =0; i6<reviewerInfos.elementAt(i4).getUnGradedApps().size(); i6++){
System.err.println("gradedApp("+i6+") status= "+reviewerInfos.elementAt(i4).getUnGradedApps().elementAt(i6).getApplicantName() );
}
}
	
	session.setAttribute( "reviewerInfos", reviewerInfos );
	session.setAttribute( "reviewers", reviewers);
	
	
	//for(int i=0; i<reviewerInfos.size(); i++){
	//	System.err.println("reviewerInfos("+i+") = "+reviewerInfos.elementAt(i).getName() );
	//}
		
	for(int i=0; i<reviewerInfos.size(); i++)
	{%>

		<%= reviewerInfos.elementAt(i).getName() %>
		<br>
		Graded
		<html:link action="/pages/chairs/GradedVNon(a)">			
			<html:param name="reviewer" value="<%=reviewerInfos.elementAt(i).getName()%>" />
			<html:param name="appsParam" value="a" />			
			<%= reviewerInfos.elementAt(i).getGradedApps().size() %>
		</html:link>
		<br>
		Ungraded
		<html:link action="/pages/chairs/GradedVNon(b)">
			<html:param name="reviewer" value="<%=reviewerInfos.elementAt(i).getName()%>" />
			<html:param name="appsParam" value="b" />
			<%= reviewerInfos.elementAt(i).getUnGradedApps().size() %>
		</html:link>
		<br>
	<%
	}
	%>



</body>
</html>